# -*- coding: utf-8; mode: snippet -*-
# name: $http.post().success(function() {...}); (angular)
# key: ahttp
# group: angular
# contributor: Chen Bin <chenbin DOT sh AT gmail>
# --
$http.${1:post}(${2:url})
  .success(function(resp) {
    console.log('resp=', resp);
    $0
  })
  .error(function(reason) {
    console.log('reason=', reason);
  });
